<?php
/* EPNZ.com(C) 2007-2016 @date 2016-11-03 17:55:37 index.php */
require_once '../power/common.php';

function checkNum($number)
 {
 if($number>1)
  {
  throw new Exception("Value must be 1 or below");
  }
 return true;
 }

//在 "try" 代码块中触发异常
try
 {
 checkNum(2);
 //If the exception is thrown, this text will not be shown
 echo 'If you see this, the number is 1 or below';
 }

//捕获异常
catch(Exception $gg)
 {
 echo 'Message: ' .$gg->getMessage();
 }

print_r($G);
$redis = new Redis();
$redis->connect('127.0.0.1', 6379);

echo $redis->get('tutorial-name');

echo PHP_EOL.'<br />';
FL::$a = 'aaa';

echo FL::fllen();

echo PHP_EOL.'<br />';

FL::$a = 'ccc';

echo FL::fllen();

class FL{
    public static $a;
    static function fllen(){
        $b='bbb';
        return self::$a.$b;
    }
}
echo PHP_EOL.'<br />';

//define('AA',"http://www.766w.com/bbs/forum.php");

//echo '{$G.site_name}';

//echo A2S('a_b_c');

echo $G['dir']['web'];
